package isnork.g2;

import java.io.File;
import java.io.FileNotFoundException;
import java.util.Scanner;

public class ExplorerConfig {
	// observation-based danger avoidance for static creatures
	public static final double c_ds = 1;
	// observation-based danger avoidance for dynamic creatures
	public static final double c_do = 1;
	// inference-based danger avoidance. Predict Times. Must > 0
	public static final int T = 6;
	public static int D = 2;
	// Return to boat
	public static int BACK = 1;
	// isnork
	public static int isnork_c = 1;
	// satisfied
	public static int SATISFIED = 1;
	// explore
	public static double ROUTE = 1;
	public static int explore = 1;
	
	public static final double Ratio = 1;
	public static final int FinalTick = 10; // final tick in explore

	public static double safeDegree = 1; // 0-1, 1 for max safe
	public static double secondChoice = 1/Math.sqrt(2);
	public static double thirdChoice = 1/Math.sqrt(2)/Math.sqrt(2);

	static {
		Scanner scanner;
		try {
			scanner = new Scanner(new File("coefficient.txt"));
			int i = 0;
			int[] cs = new int[5];
			while (scanner.hasNextInt()) {
				cs[i++] = scanner.nextInt();
			}
			// danger avoidance
			ExplorerConfig.D = cs[0];
			// explore
			ExplorerConfig.ROUTE = cs[1];
			// isnork
			ExplorerConfig.isnork_c = cs[2];
			// satisfied
			ExplorerConfig.SATISFIED = cs[3];
			// back to boat
			ExplorerConfig.BACK = cs[4];
			System.out.print(cs);
			
		} catch (FileNotFoundException e) {
			e.printStackTrace();
		}
		
	}
}
